Skip to content

feat(calibration): add automatic calibration for SO101 leadera and follower w/ Feetech STS servos#3282

Open
IsaacSinn wants to merge 1 commit intohuggingface:mainfrom
Maker-Mods:feature/auto-calibrate-feetech
Open

feat(calibration): add automatic calibration for SO101 leadera and follower w/ Feetech STS servos#3282
IsaacSinn wants to merge 1 commit intohuggingface:mainfrom
Maker-Mods:feature/auto-calibrate-feetech

Conversation

@IsaacSinn
Copy link
Copy Markdown

Type / Scope

  • Type: Feature
  • Scope: calibration, motors/feetech

Summary / Motivation

Adds a fully automated calibration CLI (lerobot-auto-calibrate-feetech) for SO-101 follower arms with Feetech STS3215 servos. The script drives each joint to its mechanical limits at low torque to measure the full range of motion no manual movement required.

Manual calibration requires the user to physically move each joint through its full range while following prompts. This is error-prone (inconsistent ranges, missed limits) and tedious, especially when calibrating multiple arms. Auto-calibration produces consistent, repeatable results with a single command.

Related issues

  • Related: N/A — new feature contribution from Maker-Mods

What changed

  • src/lerobot/motors/feetech/auto_calibration.py (new): FeetechCalibrationMixin with stall detection, mechanical range measurement, and WritePosEx utilities
  • src/lerobot/motors/feetech/calibration_defaults.py (new): shared constants and default calibration parameters
  • src/lerobot/motors/feetech/feetech.py: added FeetechCalibrationMixin to FeetechMotorsBus class inheritance
  • src/lerobot/scripts/lerobot_auto_calibrate_feetech.py (new): CLI entry point with 5-stage calibration workflow (init → unfold → calibrate joints 2–6 → calibrate joint 1 → persist)
  • pyproject.toml: added lerobot-auto-calibrate-feetech console script entry point
  • docs/source/so101.mdx: added Auto Calibrate documentation section with usage and arguments table
  • No breaking changes. Existing calibration workflows are unaffected.

How was this tested (or how to run locally)

  • Tested on a physical SO-101 follower arm (macOS, ubuntu 22 24, Python 3.12)

  • Calibration output saved to ~/.cache/huggingface/lerobot/calibration/robots/so_follower/default.json — same format as lerobot-calibrate

  • Reproduce with:

    lerobot-auto-calibrate-feetech --port /dev/ttyUSB0 --save --robot-id my_follower
    

Checklist (required before merge)

  • Linting/formatting run (ruff check and ruff format pass)
  • Documentation updated (docs/source/so101.mdx)
  • CI is green!

Reviewer notes

  • This adds a mixin (FeetechCalibrationMixin) to FeetechMotorsBus — reviewers should verify the mixin methods don't conflict with existing SerialMotorsBus methods
  • The script uses low torque and stall detection for safety, but reviewers with hardware should test on their own arms
  • Anyone in the community is free to review the PR

Adds a fully automated calibration script for SO-101 arms with Feetech
STS3215 servos. The script drives each joint to its mechanical limits at
low torque to find the full range of motion — no manual movement required.

New files:
- auto_calibration.py: FeetechCalibrationMixin with stall detection,
  range measurement, and WritePosEx utilities
- calibration_defaults.py: shared constants and default parameters
- lerobot_auto_calibrate_feetech.py: CLI script with 5-stage workflow
  (init, unfold, calibrate joints 2-6, calibrate joint 1, persist)

CLI: lerobot-auto-calibrate-feetech --port /dev/ttyUSB0 --save
@github-actions github-actions bot added documentation Improvements or fixes to the project’s docs robots Issues concerning robots HW interfaces labels Apr 4, 2026
@imstevenpmwork imstevenpmwork self-assigned this Apr 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or fixes to the project’s docs robots Issues concerning robots HW interfaces

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants